const mongoose = require('mongoose');
const Schema = mongoose.Schema;
const partnerSchema = Schema({
    //合伙人姓名
    partner_name: {
        type: String,
        required: true
    },
    //手机号
    partner_telephone: {
        type: Number,
        required: true
    },
    //销量(默认0)
    sales_volume: {
        type: Number,
        required: true
    },
    //代理级别
    agent_level: {
        type: String,
        required: true
    },
    //省
    province: {
        type: String,
        required: true
    },
    //市
    city: {
        type: String,
        required: true
    },
    //区
    area: {
        type: String,
        required: true
    },
    //钱包明细(金额、收入/支出、收支类型说明、收支事件)
    Wallet_details: {
        type: Object,
        required: true
    }
}, { versionKey: false })

module.exports = mongoose.model("partner", partnerSchema)